package com.ruoyi.offer.mapper;

import com.ruoyi.offer.domain.TotalAmount;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.math.BigDecimal;

public interface TotalAmountMapper {

    @Select("SELECT `total`  FROM total_amount WHERE mid=#{mid}")
    public BigDecimal selectByMid(Integer mid);

    @Update("UPDATE total_amount SET `total` = #{total} WHERE mid = #{mid}")
    public Integer updateByMid(@Param("mid") Integer mid, @Param("total") BigDecimal total);
}
